#pragma config(Sensor, in1,    pot_one,        sensorPotentiometer)
#pragma config(Sensor, dgtl1,  limit_one,      sensorTouch)
#pragma config(Sensor, dgtl2,  limit_two,      sensorTouch)
#pragma config(Motor,  port1,           left_motor,    tmotorVex393, openLoop, reversed)
#pragma config(Motor,  port6,           claw_motor,    tmotorVex393, openLoop)
#pragma config(Motor,  port7,           arm_motor,     tmotorVex393, openLoop)
#pragma config(Motor,  port10,          right_motor,   tmotorVex393, openLoop)
//*!!Code automatically generated by 'ROBOTC' configuration wizard               !!*//

task main()
{
	bool enable=false;
	while(true)
	{
		if(enable)
		{
			motor[left_motor]=vexRT[Ch3];
			motor[right_motor]=vexRT[Ch2];

			if(vexRT[Btn6U])
			{
				motor[arm_motor]=-100;
			}
			else if(vexRT[Btn6D])
			{
				motor[arm_motor]=100;
			}
			else
			{
				motor[arm_motor]=-10;
			}

			if(vexRT[Btn5U])
			{
				motor[claw_motor]=100;
			}
			else if(vexRT[Btn5D])
			{
				motor[claw_motor]=-100;
			}
			else
			{
				motor[claw_motor]=0;
			}
		}
		if(vexRT[Btn8U])
		{
			enable=true;
		}
		if(vexRT[Btn8D])
		{
			enable=false;
		}
	}
}
